Based on responses to surveys designed to gauge parent, student, and teacher perceptions of the quality of New York City schools, we’ll going to investigate the following questions:
Do student, teacher, and parent perceptions of NYC school quality appear to be related to demographic and academic success metrics?
Do students, teachers, and parents have similar perceptions of NYC school quality?
The next two files, masterfile11_gened_final.xlsx and masterfile11_gened_final.txt, contain survey data for “general education” schools — those that do not specifically serve populations with special needs.
The files masterfile11_d75_final.xlsx and masterfile11_d75_final.txt contain survey data for District 75 schools, which provide special education support for children with special needs such as learning or physical disabilities.
you can download these files from: https://data.cityofnewyork.us/Education/2011-NYC-School-Survey/mnz3-dyi8
We’re going to use the combined data set that have the demographic data: “combined.csv” you can download the file from: https://data.world/dataquest/nyc-schools-data/workspace/file?filename=combined.csv
library(readr)
library(dplyr)
replacing previous import by ‘rlang::dots_n’ when loading ‘dplyr’
Attaching package: ‘dplyr’
The following objects are masked from ‘package:stats’:
filter, lag
The following objects are masked from ‘package:base’:
intersect, setdiff, setequal, union
library(stringr)
library(purrr)
library(tidyr)
library(ggplot2)
combined <- read_csv("/home/matias/Documents/repos/Data-Science-Notebooks/NYC Schools Perceptions/combined.csv")
Parsed with column specification:
cols(
.default = col_double(),
DBN = [31mcol_character()[39m,
school_name = [31mcol_character()[39m,
boro = [31mcol_character()[39m
)
See spec(...) for full column specifications.
survey <- read_tsv("/home/matias/Documents/repos/Data-Science-Notebooks/NYC Schools Perceptions/2011 data files online/masterfile11_gened_final.txt")
Parsed with column specification:
cols(
.default = col_double(),
dbn = [31mcol_character()[39m,
bn = [31mcol_character()[39m,
schoolname = [31mcol_character()[39m,
studentssurveyed = [31mcol_character()[39m,
schooltype = [31mcol_character()[39m,
p_q1 = [33mcol_logical()[39m,
p_q3d = [33mcol_logical()[39m,
p_q9 = [33mcol_logical()[39m,
p_q10 = [33mcol_logical()[39m,
p_q12aa = [33mcol_logical()[39m,
p_q12ab = [33mcol_logical()[39m,
p_q12ac = [33mcol_logical()[39m,
p_q12ad = [33mcol_logical()[39m,
p_q12ba = [33mcol_logical()[39m,
p_q12bb = [33mcol_logical()[39m,
p_q12bc = [33mcol_logical()[39m,
p_q12bd = [33mcol_logical()[39m,
t_q6m = [33mcol_logical()[39m,
t_q9 = [33mcol_logical()[39m,
t_q10a = [33mcol_logical()[39m
# ... with 18 more columns
)
See spec(...) for full column specifications.
survey_d75 <- read_tsv("/home/matias/Documents/repos/Data-Science-Notebooks/NYC Schools Perceptions/2011 data files online/masterfile11_d75_final.txt")
Parsed with column specification:
cols(
.default = col_double(),
dbn = [31mcol_character()[39m,
bn = [31mcol_character()[39m,
schoolname = [31mcol_character()[39m,
studentssurveyed = [31mcol_character()[39m,
schooltype = [31mcol_character()[39m,
p_q5 = [33mcol_logical()[39m,
p_q9 = [33mcol_logical()[39m,
p_q13a = [33mcol_logical()[39m,
p_q13b = [33mcol_logical()[39m,
p_q13c = [33mcol_logical()[39m,
p_q13d = [33mcol_logical()[39m,
p_q14a = [33mcol_logical()[39m,
p_q14b = [33mcol_logical()[39m,
p_q14c = [33mcol_logical()[39m,
p_q14d = [33mcol_logical()[39m,
t_q11a = [33mcol_logical()[39m,
t_q11b = [33mcol_logical()[39m,
t_q14 = [33mcol_logical()[39m,
t_q15a = [33mcol_logical()[39m,
t_q15b = [33mcol_logical()[39m
# ... with 14 more columns
)
See spec(...) for full column specifications.
combined
survey